#include <iostream>

struct Student {
    int num;
    float score;
    struct Student * next;
};

int main() {
    struct Student a, b, c, * head, *p;
    a.num = 1001; a.score = 98.0;
    b.num = 1002, b.score = 97.0;
    c.num = 1003; c.score = 96.0;
    head = &a;
    a.next = &b;
    b.next = &c;
    c.next = NULL;
    p = head;
    do {
        printf("%1d %5.1f\n", p->num, p->score);
        p = p->next;
    } while (p != NULL);
    return 0;
}
